package cn.it.shop.pojo;

import java.util.Set;

import org.springframework.security.access.ConfigAttribute;

/**
 * Privilege entity. @author MyEclipse Persistence Tools
 */

public class Privilege implements java.io.Serializable {
	
	

	public Privilege(Integer id) {
		super();
		this.id = id;
	}
	

	public Privilege() {
		super();
	}


	private Integer id;
	private String name;
	private String url;
	private Boolean isleft;
	/* 如果当前Privilege是子菜单,那么要配置关联父菜单*/
    private Privilege parent;
    /* 如果当前Privilege是父菜单,那么要配置关联子菜单集合*/
    private Set<Privilege> childrenSet;
 // Role实现ConfigAttribute,此接口的方法,可以返回具体角色名称
 	private Set<ConfigAttribute> roleSet;
 	
	public Set<ConfigAttribute> getRoleSet() {
		return roleSet;
	}


	public void setRoleSet(Set<ConfigAttribute> roleSet) {
		this.roleSet = roleSet;
	}


	public Privilege getParent() {
		return parent;
	}

	public void setParent(Privilege parent) {
		this.parent = parent;
	}

	public Set<Privilege> getChildrenSet() {
		return childrenSet;
	}

	public void setChildrenSet(Set<Privilege> childrenSet) {
		this.childrenSet = childrenSet;
	}

	// Property accessors

	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getUrl() {
		return this.url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public Boolean getIsleft() {
		return this.isleft;
	}

	public void setIsleft(Boolean isleft) {
		this.isleft = isleft;
	}

}